package com.yehuishou.service.impl;

import java.util.Date;
import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.yehuishou.dao.BidingOrderDao;
import com.yehuishou.dao.SaleOrderDao;
import com.yehuishou.pojo.BidingOrder;
import com.yehuishou.pojo.Order;
import com.yehuishou.service.BidingOrderService;

	/**
	 * 
	 * @author ChicUniqueKing(肖洒)
	 * @className
	 * @data 2018年7月16日
	 * @description  竞价订单业务层
	 * @Team
	 * @company
	 *
	 */

@Service
public class BidingOrderServiceImpl implements BidingOrderService {

	 @Resource
	 private  BidingOrderDao bidingOrderDao;
	
	@Override
	public void insertBidingOrder(Order or) {
		//生成订单
	bidingOrderDao.insertBidingOrder(or);
		
	}

	@Override
	public List<BidingOrder> selectBidingOrder(BidingOrder or) {
		// TODO Auto-generated method stub
		return bidingOrderDao.selectBidingOrder(or);
	}

	@Override
	public int deleteOneOrder(String oid) {
		
		BidingOrder order = new BidingOrder();
		order.setOid(oid);
		return bidingOrderDao.deleteOneOrder(order);
	}

	@Override
	public BidingOrder selectOneOrder(String oid) {
		// TODO Auto-generated method stub
		BidingOrder order = new BidingOrder();
		order.setOid(oid);
		return bidingOrderDao.selectOneOrder(order);
	}

	@Override
	public int updateBidOrder(BidingOrder br) {
		// TODO Auto-generated method stub
		return bidingOrderDao.updateBidOrder(br);
	}

}
